# -*- coding: utf-8 -*-
# @Time    : 2019/7/22 11:40
# @Author  : xiao

from airtest.core.api import *
# from pocounit.suite import PocoTestSuite
from basic.UIParent import UIParent
from basic.utils.readConfig.GetConfigValue import GetValue

from commen.page.ann.indexPage import IndexPage
from commen.page.ann.loginPage import login
from commen.page.ann.myPage import myPage


class Steps(UIParent):

    @classmethod
    def do_login(self):
        '''用例名称'''
        IndexPage.isViewpager()
        myPage.clickMyBtn()
        print("点击我的页面")
        if not myPage.ifLogin():
            myPage.clickLoginBtm()
            login.clickPwdLogin()
            login.loginbyName(self,GetValue.read("login","phone"),GetValue.read("login","pass"))
        id=myPage.getUserId()
        assert_not_equal(id,0)





